package com.ibangnuo.framework.exception;

import com.ibangnuo.framework.model.response.ResultCode;

/**
 * @Author: wwy
 * @Date: 2019-12-18 16:12
 */
public class CustomException extends RuntimeException {
    //错误代码
    private ResultCode resultCode;

    /**
     * 构造方法，用来指定异常展示的格式,主要是resultCode要响应给用户
     * @param resultCode
     */
    public CustomException(ResultCode resultCode){
        this.resultCode = resultCode;
    }
    public ResultCode getResultCode(){
        return resultCode;
    }
}
